package a.g;

import a.f.b.a;
import a.f.d.a.fc;
import a.f.rc;
import a.f.t;
import a.h.cc;
import a.h.dc;
import a.j.g;
import a.j.ld;

import java.awt.*;

public class p
  extends h
{
  private static final String q = "FAMILY_TREE_LAYOUTER";
  private static final String r = "FAMILY_PROPERTIES";
  private static final String s = "FAMILY_COLOR";
  private static final String t = "MALE_COLOR";
  private static final String u = "FEMALE_COLOR";
  private static final String v = "LAYOUT";
  private static final String w = "ORIENTATION";
  private static final String x = "RIGHT_TO_LEFT";
  private static final String y = "BOTTOM_TO_TOP";
  private static final String z = "LEFT_TO_RIGHT";
  private static final String A = "TOP_TO_BOTTOM";
  private static final String B = "SINGLE_DIRECT_BELOW";
  private static final String C = "FAMILIES_ALWAYS_BELOW";
  private static final String D = "DISTANCES";
  private static final String E = "SIBLING_DISTANCES";
  private static final String F = "HORIZONTAL_SPACING";
  private static final String G = "NODE_TO_NODE_DISTANCE";
  private static final String H = "GENERATION_DISTANCES";
  private static final String I = "VERTICAL_SPACING";
  private static final String J = "MINIMUM_LAYER_DISTANCE";
  private static final String K = "MINIMUM_FIRST_SEGMENT";
  private static final String L = "MINIMUM_LAST_SEGMENT";
  private static final String M = "ADVANCED_LAYOUT";
  private static final String N = "COMPONENT_LAYOUTER";
  private static final String O = "USE_COMPONENT_LAYOUTER";
  private static final String P = "COMPONENT_DISTANCE";
  private static final String Q = "COMPONENT_STYLE";
  private static final String R = "COMPONENT_STYLE_NONE";
  private static final String S = "COMPONENT_STYLE_ROWS";
  private static final String T = "COMPONENT_STYLE_SINGLE_ROW";
  private static final String U = "COMPONENT_STYLE_SINGLE_COLUMN";
  private static final String V = "COMPONENT_STYLE_PACKED_COMPACT_RECTANGLE";
  private static final String W = "COMPONENT_STYLE_PACKED_RECTANGLE";
  private static final String X = "COMPONENT_STYLE_PACKED_CIRCLE";
  private static final String Y = "COMPONENT_STYLE_PACKED_COMPACT_CIRCLE";
  private static final String Z = "SORT_BY_SEX";
  private static final String ab = "DO_NOT_SORT";
  private static final String bb = "FEMALE_LEFT";
  private static final String cb = "FEMALE_ALWAYS_LEFT";
  private static final String db = "MALE_LEFT";
  private static final String eb = "MALE_ALWAYS_LEFT";
  private static final String fb = "NODE_ALIGNMENT";
  private static final String gb = "NODE_ALIGN_TOP";
  private static final String hb = "NODE_ALIGN_CENTER";
  private static final String ib = "NODE_ALIGN_BOTTOM";
  private static final Object[] jb = { "DO_NOT_SORT", "FEMALE_LEFT", "FEMALE_ALWAYS_LEFT", "MALE_LEFT", "MALE_ALWAYS_LEFT" };
  private static final Object[] kb = { "TOP_TO_BOTTOM", "LEFT_TO_RIGHT", "BOTTOM_TO_TOP", "RIGHT_TO_LEFT" };
  private static final Object[] lb = { "NODE_ALIGN_TOP", "NODE_ALIGN_CENTER", "NODE_ALIGN_BOTTOM" };
  private static final Object[] mb = { "COMPONENT_STYLE_NONE", "COMPONENT_STYLE_ROWS", "COMPONENT_STYLE_SINGLE_ROW", "COMPONENT_STYLE_SINGLE_COLUMN", "COMPONENT_STYLE_PACKED_RECTANGLE", "COMPONENT_STYLE_PACKED_COMPACT_RECTANGLE", "COMPONENT_STYLE_PACKED_CIRCLE", "COMPONENT_STYLE_PACKED_COMPACT_CIRCLE" };
  public static int nb;
  
  public p()
  {
    super("FAMILY_TREE_LAYOUTER", "yFiles Layout Team", "Layouter for genealogic data");
  }
  
  protected dc j()
  {
    dc localdc = new dc(a());
    a.h.z localz = new a.h.z(localdc);
    localdc.l("FAMILY_PROPERTIES");
    localdc.a("FAMILY_COLOR", Color.black, true);
    localdc.a("MALE_COLOR", new Color(16764057), true);
    localdc.a("FEMALE_COLOR", new Color(13421823), true);
    localdc.l("LAYOUT");
    localdc.a("ORIENTATION", kb, 0);
    localdc.a("SINGLE_DIRECT_BELOW", true);
    localdc.a("FAMILIES_ALWAYS_BELOW", false);
    localdc.a("NODE_ALIGNMENT", lb, 0);
    localdc.a("SORT_BY_SEX", jb, 0);
    localdc.l("DISTANCES");
    cc localcc1 = new cc();
    localcc1.a("OptionGroup.title", "SIBLING_DISTANCES");
    localcc1.a(localdc.a("HORIZONTAL_SPACING", 40.0D, 0.0D, 400.0D));
    localcc1.a(localdc.a("NODE_TO_NODE_DISTANCE", 40.0D, 0.0D, 400.0D));
    cc localcc2 = new cc();
    localcc2.a("OptionGroup.title", "GENERATION_DISTANCES");
    localcc2.a(localdc.a("VERTICAL_SPACING", 10.0D, 0.0D, 100.0D));
    localcc2.a(localdc.a("MINIMUM_LAYER_DISTANCE", 40.0D, 0.0D, 400.0D));
    localcc2.a(localdc.a("MINIMUM_FIRST_SEGMENT", 40.0D, 0.0D, 400.0D));
    localcc2.a(localdc.a("MINIMUM_LAST_SEGMENT", 20.0D, 0.0D, 400.0D));
    localdc.l("ADVANCED_LAYOUT");
    localdc.a("USE_COMPONENT_LAYOUTER", true);
    cc localcc3 = new cc();
    localcc3.a("OptionGroup.title", "COMPONENT_LAYOUTER");
    localcc3.a(localdc.a("COMPONENT_DISTANCE", 40));
    localcc3.a(localdc.a("COMPONENT_STYLE", mb, 1));
    localz.a("USE_COMPONENT_LAYOUTER", Boolean.TRUE, "COMPONENT_DISTANCE");
    return localdc;
  }
  
  public void n()
  {
    g localg = e();
    a locala = new a();
    b(locala);
    a(locala);
    if ((f.p != 0) || (localg.c("y.layout.genealogy.FamilyTreeLayouter.DP_KEY_FAMILY_TYPE") != null)) {
      localg.j("y.layout.genealogy.FamilyTreeLayouter.DP_KEY_FAMILY_TYPE");
    }
  }
  
  public void b(rc paramrc)
  {
    int i = f.p;
    boolean bool = f.o;
    if ((i != 0) || ((paramrc instanceof a)))
    {
      a locala = (a)paramrc;
      dc localdc = i();
      g localg = e();
      locala.a(localdc.f("HORIZONTAL_SPACING"));
      locala.b(localdc.f("VERTICAL_SPACING"));
      locala.i(localdc.g("FAMILIES_ALWAYS_BELOW"));
      locala.h(localdc.g("SINGLE_DIRECT_BELOW"));
      if (i == 0) {
        if (localdc.j("ORIENTATION").equals("TOP_TO_BOTTOM"))
        {
          locala.a((byte)0);
          if (i != 0) {
            break label209;
          }
          if (!bool) {
            break label199;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("ORIENTATION").equals("LEFT_TO_RIGHT"))
        {
          locala.a((byte)1);
          if (i != 0) {
            break label209;
          }
          if (!bool) {
            break label199;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("ORIENTATION").equals("BOTTOM_TO_TOP"))
        {
          locala.a((byte)2);
          if (i != 0) {
            break label209;
          }
        }
      }
      if ((bool) && (localdc.j("ORIENTATION").equals("RIGHT_TO_LEFT"))) {
        locala.a((byte)3);
      }
      label199:
      locala.e(localdc.g("USE_COMPONENT_LAYOUTER"));
      label209:
      t localt = (t)locala.e();
      localt.b(localdc.e("COMPONENT_DISTANCE"));
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_NONE"))
        {
          localt.a((byte)0);
          if ((i == 0) && (!bool)) {
            break label497;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_PACKED_CIRCLE"))
        {
          localt.a((byte)6);
          if ((i == 0) && (!bool)) {
            break label497;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_PACKED_COMPACT_CIRCLE"))
        {
          localt.a((byte)7);
          if ((i == 0) && (!bool)) {
            break label497;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_PACKED_COMPACT_RECTANGLE"))
        {
          localt.a((byte)5);
          if ((i == 0) && (!bool)) {
            break label497;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_PACKED_RECTANGLE"))
        {
          localt.a((byte)4);
          if ((i == 0) && (!bool)) {
            break label497;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_ROWS"))
        {
          localt.a((byte)1);
          if ((i == 0) && (!bool)) {
            break label497;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_SINGLE_COLUMN")) {
          localt.a((byte)3);
        }
      }
      if ((i != 0) || ((bool) && (localdc.j("COMPONENT_STYLE").equals("COMPONENT_STYLE_SINGLE_ROW")))) {
        localt.a((byte)2);
      }
      label497:
      a.f.d.e locale = new a.f.d.e();
      locala.a(locale);
      fc localfc = locale.W();
      if (i == 0) {
        if (localdc.j("NODE_ALIGNMENT").equals("NODE_ALIGN_TOP"))
        {
          localfc.b(0.0D);
          locala.a(-1);
          if (i != 0) {
            break label648;
          }
          if (!bool) {
            break label626;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("NODE_ALIGNMENT").equals("NODE_ALIGN_CENTER"))
        {
          localfc.b(0.5D);
          locala.a(0);
          if (i != 0) {
            break label648;
          }
        }
      }
      if ((bool) && (localdc.j("NODE_ALIGNMENT").equals("NODE_ALIGN_BOTTOM")))
      {
        localfc.b(1.0D);
        locala.a(1);
      }
      label626:
      locale.a(localdc.f("MINIMUM_LAYER_DISTANCE"));
      locale.b(localdc.f("NODE_TO_NODE_DISTANCE"));
      label648:
      a.f.d.a.z localz = locale.U();
      localz.a(localdc.f("MINIMUM_FIRST_SEGMENT"));
      localz.b(localdc.f("MINIMUM_LAST_SEGMENT"));
      localz.c(true);
      if (i == 0) {
        if (localdc.j("SORT_BY_SEX").equals("DO_NOT_SORT"))
        {
          locala.b(0);
          if ((i == 0) && (!bool)) {
            break label838;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("SORT_BY_SEX").equals("FEMALE_LEFT"))
        {
          locala.b(1);
          if ((i == 0) && (!bool)) {
            break label838;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("SORT_BY_SEX").equals("FEMALE_ALWAYS_LEFT"))
        {
          locala.b(2);
          if ((i == 0) && (!bool)) {
            break label838;
          }
        }
      }
      if (i == 0) {
        if (localdc.j("SORT_BY_SEX").equals("MALE_LEFT")) {
          locala.b(3);
        }
      }
      if ((i != 0) || ((bool) && (localdc.j("SORT_BY_SEX").equals("MALE_ALWAYS_LEFT")))) {
        locala.b(4);
      }
      label838:
      a.i.p local0 = null;
      if (localg.c("y.layout.genealogy.FamilyTreeLayouter.DP_KEY_FAMILY_TYPE") == null)
      {
        local0 = new a.i.p()
        {
          private final g val$graph;
          private final dc val$op;
          
          public Object get(Object paramAnonymousObject)
          {
            int i = f.p;
            ld localld = this.val$graph.w((a.c.e)paramAnonymousObject);
            Color localColor = localld.o();
            if (i == 0) {
              if (localColor != null)
              {
                if (i != 0) {
                  break label56;
                }
                if (localColor.equals(this.val$op.j("MALE_COLOR"))) {
                  return "MALE";
                }
              }
            }
            label56:
            if (i == 0) {
              if (localColor != null)
              {
                if (i != 0) {
                  break label89;
                }
                if (localColor.equals(this.val$op.j("FEMALE_COLOR"))) {
                  return "FEMALE";
                }
              }
            }
            label89:
            if (((i != 0) || (localColor != null)) && (localColor.equals(this.val$op.j("FAMILY_COLOR")))) {
              return "FAMILY";
            }
            return null;
          }
        };
        localg.a("y.layout.genealogy.FamilyTreeLayouter.DP_KEY_FAMILY_TYPE", local0);
      }
    }
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.g.p

 * JD-Core Version:    0.7.0.1

 */